﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using PsychveyApp1.classes;

namespace PsychveyApp1
{
    public partial class UserEditedDetails : System.Web.UI.Page
    {
        protected void Page_Load(object sender, EventArgs e)
        {
            if ((!Page.IsPostBack))
            {
                lblUsernameMyAccount.Text = (string)(Session["username"]);

                UserAccount update = (UserAccount)(Session["updatedUser"]);

                lblAccountType.Text = update.accountTypeSelected;
                lblExpirationDateForPremium.Text = update.expirationDateForPremium;
                lblUsername.Text = update.username;
                lblUserPassword.Text = update.password;
                lblUserFullName.Text = update.userFullName;
                lblEmail.Text = update.email;
            }
        }

        protected void ddlUser_SelectedIndexChanged(object sender, EventArgs e)
        {

        }

        protected void btnProceed_Click(object sender, EventArgs e)
        {
            if (ddlUser.SelectedIndex == 1)
            {
               
               Response.Redirect("UserAccountHome.aspx");
            }
            else if (ddlUser.SelectedIndex == 2)
            {
                Response.Redirect("Home.aspx");
            }
        }

        protected void AdminLoginShortcut_Click(object sender, EventArgs e)
        {
            Response.Redirect("AdminLogin.aspx");
        }

        protected void LinkButton3_Click(object sender, EventArgs e)
        {
            Response.Redirect("MySurvey.aspx");
        }
    }
}